5. Frequently Asked QuestionsΒΆ

Can I use the MySql database instead of SQLite?

Yes. To do this, do the following:

  1. Run $ pip3 install pymysql==0.6.7

  2. Add into manage.py this lines befor line if __name__ == "__main__"::

    import pymysql
    pymysql.install_as_MySQLdb()
    
  3. Set Django DATABASES settings in config/local.py like

    DATABASES = {
      'default': {
          'ENGINE': 'django.db.backends.mysql',
          'NAME': 'mysmile',
          'USER': 'root',
          'PASSWORD': 'password',
          'HOST': '127.0.0.1',
          'PORT': '3306',
      }
    }
    
  4. Create database mysmile

  5. Run command $ make newdb

  6. Run local server $ make run